<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <script>
        // 将数组 ['关羽', '张飞', '程咬金', '吕布']; 的内容反过来存放
        //        ['吕布', '程咬金', '张飞', '关羽']
        let arr = ['关羽', '张飞', '程咬金', '吕布'];
        let arr1 = new Array();
        for(let i = arr.length-1;i>=0;i--){
            arr1[arr.length-1-i] =arr[i];
        }
        console.log(arr1);
    </script>
</body>

</html>